/*
 * Copyright(c) 2018-? the original author[Wien(luweien@aliyun.com)] or authors.
 *
 */
package org.doll.it.base.util;

import java.util.Collection;
import java.util.Map;

/**
 * 集合工具类
 * 
 * @author Wien(luweien@aliyun.com)
 *
 */
public class CollectionUtils extends org.springframework.util.CollectionUtils {

	/**
	 * Return {@code false} if the supplied Collection is {@code null} or empty.
	 * Otherwise, return {@code true}.
	 * @param collection the Collection to check
	 * @return whether the given Collection is not empty
	 */
	public static boolean isNotEmpty(Collection<?> collection) {
		return !isEmpty(collection);
	}

	/**
	 * Return {@code false} if the supplied Map is {@code null} or empty.
	 * Otherwise, return {@code trueF}.
	 * @param map the Map to check
	 * @return whether the given Map is not empty
	 */
	public static boolean isNotEmpty(Map<?, ?> map) {
		return !isEmpty(map);
	}
}
